Skip to content

HDDS-15281. Missing LifeCycleState codec in ScmCodecFactory#10276

Merged
sarvekshayr merged 2 commits into
apache:masterfrom
sarvekshayr:HDDS-15281
May 15, 2026
Merged

HDDS-15281. Missing LifeCycleState codec in ScmCodecFactory#10276
sarvekshayr merged 2 commits into
apache:masterfrom
sarvekshayr:HDDS-15281

Conversation

@sarvekshayr
Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

ContainerStateManager#transitionDeletingOrDeletedToTargetState is annotated with @Replicate and takes org.apache.hadoop.hdds.protocol.proto.HddsProtos.LifeCycleState as a parameter. After HDDS-14748 (non-reflection ScmGeneratedMessageCodec / explicit codec registration for Ratis serialization), callers need a ScmCodec registered for every protobuf-derived type used in replicated method arguments—including protobuf enums handled via ScmEnumCodec.

LifeCycleState was not registered in ScmCodecFactory. That can cause InvalidProtocolBufferException (“Codec not found …”) when the leader submits or followers apply this Ratis transaction.

What is the link to the Apache JIRA

HDDS-15281

How was this patch tested?

Added a new test to scan every @Replicate method on known SCM handlers and asserts each parameter type resolves to a codec.

HDDS-15281. Missing LifeCycleState codec in ScmCodecFactory

HDDS-15281. Missing LifeCycleState codec in ScmCodecFactory
@sarvekshayr sarvekshayr requested a review from sumitagrawl May 15, 2026 08:55
Copy link
Copy Markdown
Contributor

@sumitagrawl sumitagrawl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@sarvekshayr sarvekshayr requested a review from adoroszlai May 15, 2026 11:39
@adoroszlai
Copy link
Copy Markdown
Contributor

Thanks @sarvekshayr for updating the patch.

@sarvekshayr sarvekshayr merged commit 617dee9 into apache:master May 15, 2026
47 checks passed
@sarvekshayr
Copy link
Copy Markdown
Contributor Author

Thanks @sumitagrawl and @adoroszlai for the review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants